.components {
  @mixin navbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
  }
  @mixin navbar-item {
    display: block;
    flex: 1;
    text-align: center;
  }
  &.site-header {
    @include navbar;
    position: fixed;
    left: 0;
    top: 0;
    width: 100%;
    z-index: 1;
    height: (82rem/28);
    line-height: (82rem/28);
    border-bottom: 1px solid #323232;
    & > * {
      @include navbar-item;
      font-size: (34rem/28);
      color: #464648;
      background: url("../images/site-header-bg.png") repeat-x;
      background-size: contain;
      border-left: 1px solid #e5d5b9;
      border-right: 1px solid #928368;
      text-decoration: none;
      &.active {
        background-image: url("../images/site-header-bg-active.png");
      }
      &:first-child {
        border-left: 0;
      }
      &:last-child {
        border-right: 0;
      }
    }
  }
  &.site-footer {
    @include navbar;
    height: (78rem/28);
    background: url("../images/site-footer-bg.png") repeat-x;
    line-height: (78rem/28);
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    z-index: 1;
    & > a {
      @include navbar-item;
      text-decoration: none;
      background: center no-repeat;
      background-size: 50%;
      font-size: 0;
      &.activity-introduce {
        background-image: url("../images/site-footer-activity-introduce.png");
      }
      &.join-activity {
        border-left: 1px solid #cbcbcb;
        background-image: url("../images/site-footer-join-activity.png");
      }
      &.safe-protect {
        background-image: url("../images/site-footer-safe-protect.png");
      }
    }
  }
  &.btn-red {
    font-size: (36rem/28);
    font-weight: bold;
    color: #fffcfd;
    width: (292rem/28);
    height: (83rem/28);
    text-align: center;
    line-height: (83rem/28);
    background: url("../images/btn-red.png") no-repeat;
    background-size: 100% 100%;
    display: block;
    text-decoration: none;
  }
  &.btn-black {
    height: (80rem/28);
    line-height: (80rem/28);
    font-size: (36rem/28);
    color: #bd8e54;
    text-align: center;
    display: block;
    text-decoration: none;
    border: 0;
    outline: 0;
    background: url("../images/btn-black-bg.png") repeat-x;
  }
  @keyframes rotate {
    0% {
      transform: rotate(0deg);
    }
    100% {
      transform: rotate(360deg);
    }
  }
  @keyframes flashing {
    0% {
      opacity: 1;
    }
    100% {
      opacity: 0;
    }
  }
  &.loading {
    width: (200rem/28);
    height: (200rem/28);
    border-radius: 4px;
    background: rgba(0, 0, 0, 0.7);
    position: fixed;
    z-index: 999;
    top: 50%;
    left: 50%;
    margin-top: -(100rem/28);
    margin-left: -(100rem/28);
    .outer {
      border-radius: 50%;
      border: 5px solid rgba(255, 255, 255, 0.3);
      width: (160rem/28);
      height: (160rem/28);
      position: absolute;
      left: 50%;
      top: 50%;
      margin-top: -(80rem/28);
      margin-left: -(80rem/28);
      box-sizing: border-box;
      line-height: (150rem/28);
      text-align: center;
      color: white;
      font-size: 1rem;
      animation: flashing 2s linear infinite alternate;
    }
    .inner {
      border-radius: 50%;
      border: 5px solid rgba(255, 255, 255, 0.8);
      width: (160rem/28);
      height: (160rem/28);
      position: absolute;
      left: 50%;
      top: 50%;
      margin-top: -(80rem/28);
      margin-left: -(80rem/28);
      box-sizing: border-box;
      clip: rect(0px, 40px, 40px, 0px);
      animation: rotate 2s linear infinite;
    }
  }
}